<?php
declare(strict_types=1);

namespace App\Controller\Admin;

use App\Controller\AbstractController;
use App\Core\Response;
use Hyperf\View\RenderInterface;
use Hyperf\Contract\SessionInterface;
use Hyperf\Di\Annotation\Inject;
class AdminController extends AbstractController
{
    /**
     * @Inject
     * @var Response
     */
    protected $response;
    
    /**
     * @Inject
     * @var RenderInterface
     */
    protected $render;

//    /**
//     * @Inject
//     * @var SessionInterface
//     */
//    public $session;

//    public function __construct(SessionInterface $session)
//    {
//        $this->session = $session;
//    }

    public function view($template,$data=[])
    {
        return $this->render->render($template,$data);
    }
}